#!/usr/bin/env python

import os
import sys

sys.path.append(os.path.join(os.path.dirname(__file__), '..'))
from runtest_dalton import Filter, TestRun

test = TestRun(__file__, sys.argv)

f = Filter()
f.add(abs_tolerance = 1.0e-5)
test.run(['pehf_mep_skipqm.dal'], ['water.mol'], ['water.pot'], f={'m0_mep.cube': f, 'ind_mep.cube': f, 'm0_field_1.cube': f, 'm0_field_2.cube': f, 'm0_field_3.cube': f, 'ind_field_1.cube': f, 'ind_field_2.cube': f, 'ind_field_3.cube': f}, args='-get "ind_field_1.cube  ind_field_2.cube  ind_field_3.cube  ind_mep.cube  m0_field_1.cube  m0_field_2.cube  m0_field_3.cube  m0_mep.cube"')

g = Filter()
g.add(abs_tolerance = 1.0e-5)
test.run(['pehf_mep_skipmul.dal'], ['water.mol'], ['water.pot'], f={'qm_mep.cube': g}, args='-get "qm_mep.cube"')

sys.exit(test.return_code)
